package cn.wolfcode.luowowo.comment.domain;

import lombok.AllArgsConstructor;
import lombok.Getter;
import lombok.NoArgsConstructor;
import lombok.Setter;
import org.springframework.data.annotation.Id;
import org.springframework.data.mongodb.core.mapping.Document;

import java.io.Serializable;
import java.util.ArrayList;
import java.util.Date;
import java.util.List;

/**
 * 商城评论
 */
@Setter
@Getter
@Document("itemshop_comment")   //文档所在集合名字
@AllArgsConstructor
@NoArgsConstructor
public class ItemShopComment implements Serializable {
    @Id
    private String id;  //spring - data 默认封装成 ObjectId

    private Long fromId;    //用户id
    private String fromName;  //用户名
    private int fromLevel;
    private String fromImg;     //头像

    private Date date;    //创建时间
    private String content;      //评论内容

    private int state;

    private Long told = -1L; //关联的评论的作者

    private String toName;  //关联评论的作者名

}
